/*************************************************
Author: byron 
Date: 12/12/2013
Description:
Notes:
*************************************************/

#ifndef __CLoginRewardMgr_h__
#define __CLoginRewardMgr_h__

#include "CDayWishCfg.h"

class CPlayerOnlineData;
class MsgReqLoginReward;
class MsgAnsLoginReward;

class CLoginRewardMgr
{
public:
    enum CMD_LOGIN_REWARD_SUB_TAG
    {
        CMD_LOGIN_REWARD_SUB_INFO = 1,        //获取信息
        CMD_LOGIN_REWARD_SUB_AWARD = 2,       //领取奖励
    };

    CLoginRewardMgr()
    {
    }

    virtual ~CLoginRewardMgr()
    {
    }

    void UpdateData(CPlayerDetailInfoEx1& stPlayerDetailEx1, bool& bUpdateToDB);

    int GetInfo(CPlayerDetailInfoEx1& stPlayerDetailEx1,
            MsgAnsLoginReward& stAns);

    int GetAward(CPlayerDetailInfoEx1& stPlayerDetailEx1,
            CPlayerOnlineData& stPlayerOnline, MsgReqLoginReward& stReq,
            MsgAnsLoginReward& stAns);

    void NotifyAllOnlineUsers();
};

#endif // __CLoginRewardMgr_h__

